package com.yazi.mxz.common.service;

import java.util.List;

import com.myframework.smhj.common.exception.MyException;
import com.myframework.smhj.hibernate.dao.Service;

import com.yazi.mxz.common.entity.beans.Cook;
import com.yazi.mxz.common.entity.beans.Material;

public interface CookService extends Service<Cook> {
	
	
	/**
	 * 添加/修改菜谱<br>
	 * 当cook.cookId大于0值为修改,否则为添加.
	 * @param cook 菜谱(表单对象)
	 * @param materials 食材(表单对象)
	 * @return
	 */
	Cook addOrEdit(Cook cook, List<Material> materials) throws MyException;
	
	/**
	 * 删除菜谱
	 * @param cookId
	 */
	void remove(long cookId);
	
}
